// 司机管理接口
import { createAPI } from '@/utils/request'

// 获取司机详情
export const driverDetailAPI = id => createAPI(`/driver/${id}`, 'get')

// 保存司机信息
export const updateDriverDetailAPI = data => createAPI(`/driver/${data.userId}`, 'put', data)

// 获取司机驾驶证信息
export const getLicenseDetailAPI = id => createAPI(`/driverLicense/${id}`, 'get')

// 保存司机驾驶证信息
export const updateLicenseDetailAPI = data => createAPI(`/driverLicense`, 'post', data)

// 获取已停用的车辆
export const unWorkingTrucksAPI = data => createAPI(`/truck/page`, 'get', { page: 1, pageSize: 100 })

// 司机安排车辆
export const driverTrunkAPI = data => createAPI('/driver/truckDrivers', 'post', data)
